home *** CD-ROM | disk | FTP | other *** search
/ Light ROM 1 / LIGHT-ROM 1 (Amiga Library Services)(1994).iso / ffdisks / d892.lha / Indent / source / source.lha / sys.h < prev    next >
C/C++ Source or Header  |  1993-06-24  |  2KB  |  77 lines

  1. /* Copyright (C) 1992 Free Software Foundation, Inc.
  2.  
  3.    This program is free software; you can redistribute it and/or modify
  4.    it without restriction.
  5.  
  6.    This program is distributed in the hope that it will be useful,
  7.    but WITHOUT ANY WARRANTY; without even the implied warranty of
  8.    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  */
  9.  
  10. #include <stdio.h>
  11. #ifdef AMIGA
  12. /* For malloc, etc... */
  13. #include <stdlib.h>
  14. #include <string.h>
  15. #endif /* AMIGA */
  16.  
  17. /* Values of special characters. */
  18. #define TAB '\t'
  19. #define EOL '\n'
  20. #define BACKSLASH '\\'
  21.  
  22. #ifdef DEBUG
  23. extern int debug;
  24. #endif
  25.  
  26. #ifdef __GNUC__
  27. #define INLINE __inline__
  28. #else
  29. #define INLINE
  30. #endif
  31.  
  32. #ifdef VMS
  33. # define ONE_DOT_PER_FILENAME 1
  34. # define NODIR 1
  35. # define PROFILE_FORMAT "%s%s"
  36. # define BACKUP_SUFFIX_STR    "_"
  37. # define BACKUP_SUFFIX_CHAR   '_'
  38. # define BACKUP_SUFFIX_FORMAT "%s._%d_"
  39. # define SYS_READ vms_read    /* Defined in io.c */
  40. # ifdef VAXC
  41. #  include <unixio.h>
  42. # endif
  43. #endif /* VMS */
  44.  
  45. #ifdef __MSDOS__
  46. #define ONE_DOT_PER_FILENAME 1
  47. #define USG   1
  48. #define NODIR 1
  49. #endif /* __MSDOS__ */
  50.  
  51. /* configure defines USG if it can't find bcopy */
  52.  
  53. #ifndef AMIGA
  54. #ifndef USG
  55. #define memcpy(dest,src,len) bcopy((src),(dest),len)
  56. #endif
  57. #endif /* !AMIGA */
  58.  
  59. struct file_buffer
  60. {
  61.   char *name;
  62.   unsigned long size;
  63.   char *data;
  64. };
  65.  
  66. extern struct file_buffer *read_file (), *read_stdin ();
  67.  
  68. /* Standard memory allocation routines.  */
  69. #ifndef AMIGA
  70. char *malloc ();
  71. char *realloc ();
  72. #endif /* !AMIGA */
  73.  
  74. /* Similar, but abort with an error if out of memory (see globs.c).  */
  75. char *xmalloc ();
  76. char *xrealloc ();
  77.